﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using imaginecup.information;
using imaginecup.objectManager;
using Imaginecup.gameState.malaria.componentInit;
using imaginecup.util;
using Microsoft.Xna.Framework;
using Imaginecup.sprite.factory;
using Imaginecup.sprite;

namespace Imaginecup.gameState.malaria.component.etc
{
    public class CmpMenuIcon : BaseEntityComponent
    {
        public override void Release()
        {
        }


        public CmpMenuIcon(GObjectID a_GID, ObjectManager objMan)
            : base(a_GID, objMan, ComponentTypeID.CID_MESSAGE_NONE)
        {

            m_Info = new EntityInfo();
            m_Info.mSize = new Vector2(59, 59);
            m_Info.mPosition = new Vector2(738, 8);


        }


        public override void Init()
        {
            FactorySpriteInfo spriteInfo = new FactorySpriteInfo(SPRITE_TYPE_ID.NORMAL_SPRITE, "Menu", null);
            SpriteFactory spriteFactory = new SpriteFactory();

            ICmpRender render = new CmpDefaultRender(m_ObjectID, m_ObjectMan, (ISprite)spriteFactory.GetObject(spriteInfo), ComponentTypeID.CID_RENDER_ITEMPANEL);
            m_ObjectMan.AddComponent(render);

            base.Init();
        }



        public override void Update(GameTime gameTime)
        {
            base.Update(gameTime);
        }
        public override EMessageResult HandleMessage(GMessage a_Msg)
        {

            return base.HandleMessage(a_Msg);
        }
    }
}
